package com.financing.wap.dao.impl;


import java.sql.SQLException;
import java.util.List;
import java.util.Map;
import org.springframework.stereotype.Repository;
import com.financing.wap.dto.DstUserWechatSendLogDTO;
import com.financing.wap.dao.IDstUserWechatSendLogDao;
import com.financing.wap.common.SqlName;
/**
 * dst_user_wechat_send_log  
 * 用户微信推送流水  数据访问层实现类
 * @author huqiyun
 *
 */
 
@Repository("dstUserWechatSendLogDao")
public class DstUserWechatSendLogDaoImpl extends BaseDaoImpl<DstUserWechatSendLogDTO, java.lang.Integer> implements IDstUserWechatSendLogDao {


	@Override
	public int insert(DstUserWechatSendLogDTO dstUserWechatSendLog) throws SQLException {
		return (Integer) this.sqlMapClientTemplate.insert(SqlName.DstUserWechatSendLogSql.insert, dstUserWechatSendLog);
	}

	@Override
	public void update(DstUserWechatSendLogDTO dstUserWechatSendLog) throws SQLException {
		this.sqlMapClientTemplate.update(SqlName.DstUserWechatSendLogSql.update, dstUserWechatSendLog);
	}

	@Override
	public void updateForce(DstUserWechatSendLogDTO dstUserWechatSendLog) throws SQLException {
		this.sqlMapClientTemplate.update(SqlName.DstUserWechatSendLogSql.updateForce, dstUserWechatSendLog);
	}

	@Override
	public void delete(Integer id) throws SQLException {
		this.sqlMapClientTemplate.delete(SqlName.DstUserWechatSendLogSql.delete,id);
	}
	
	@SuppressWarnings("unchecked")	
	@Override
	public List<DstUserWechatSendLogDTO> queryList(DstUserWechatSendLogDTO dstUserWechatSendLog) throws SQLException {
		return this.sqlMapClientTemplate.queryForList(SqlName.DstUserWechatSendLogSql.queryList, dstUserWechatSendLog);
	}

	@Override
	public int queryListCount(DstUserWechatSendLogDTO dstUserWechatSendLog) throws SQLException {
		return (Integer) this.sqlMapClientTemplate.queryForObject(SqlName.DstUserWechatSendLogSql.queryListCount, dstUserWechatSendLog);
	}

	@Override
	public DstUserWechatSendLogDTO loadById(Integer id) throws SQLException {
		return  (DstUserWechatSendLogDTO)this.getSqlMapClientTemplate().queryForObject(SqlName.DstUserWechatSendLogSql.loadById,id);
	}

	@Override
	public Class<DstUserWechatSendLogDTO> getEntityClass() {
		return DstUserWechatSendLogDTO.class;
	}
 	
}
